package com.zswl.bus.login;

import android.content.Context;
import android.os.Bundle;
import android.support.annotation.Nullable;
import android.support.v7.app.AppCompatActivity;

import com.zswl.bus.Api;
import com.zswl.bus.ApiService;

/**
 * Created by Administrator on 2018/6/9 0009.
 */

public abstract class BaseActivity extends AppCompatActivity {
    protected String TAG = this.getClass().getSimpleName();
    protected Context context;
    protected Api api = null;

    @Override
    protected void onCreate(@Nullable Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        context = this;
        api=ApiService.getInstance().getApi();
        setContentView(getLayoutId());
        init();
    }



    protected abstract int getLayoutId();

    protected abstract void init();


}
